class Herolist_item extends eui.ItemRenderer implements  eui.UIComponent {
	public ce_select:eui.CheckBox;
	public constructor() {
		super();
		this.skinName = 'heroListItem'
	}

	protected partAdded(partName:string,instance:any):void
	{
		super.partAdded(partName,instance);
	}


	protected childrenCreated():void
	{
		super.childrenCreated();
		this.ce_select.addEventListener(egret.Event.CHANGE,()=>{
			egret.log(`CheckBox变化前：${this.data.isSelected}`)
			this.data.isSelected = this.ce_select.selected;
			egret.log(`CheckBox变化后：${this.data.isSelected}`)
		},this)
	}
	protected dataChanged(){
		this.ce_select.selected = this.data.isSelected;
	}
	
}